package com.addplus.townmall.server.api.mapper.town;

import com.addplus.townmall.server.api.model.town.GiftCardType;
import com.addplus.townmall.server.api.utils.BaseAddMapper;
import org.apache.ibatis.annotations.Select;

/**
 * <p>
 * 商城礼品卡类型 Mapper 接口
 * </p>
 *
 * @author zhangjiehang
 * @since 2018-08-27
 */
public interface GiftCardTypeMapper extends BaseAddMapper<GiftCardType> {

    @Select("select IFNULL(max(sort)+1,1) as sort from gift_card_type where is_delete=0")
    Integer maxSort();
}
